package com.situ.stmall.controller.api;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.situ.stmall.service.goodsSortService;
/**
 * 获取商品分类信息的接口
 * @author dell
 *
 */
@RestController
@RequestMapping("/api/goodsSort")
public class APIGoodsSortController {
	
	@Autowired
	private goodsSortService goodsSortService;

	/**
	 * 获取一级分类
	 */
	@GetMapping("/getParent")
	public List getParent() {
		//1获取参数
		//2调用service
		List list = goodsSortService.getParent();
		//3返回数据
		return list;
	}
}
